package MyGenerics;

public class MyArrayListDemo1 {
    public static void main(String[] args) {
        MyArrayList<String> list = new MyArrayList<>();
        list.add("zhangdeming");
        list.add("123");
        list.add("456");
        list.add("789");
        list.add("000");
        String s1 = list.get(0);
        String s2 = list.get(1);
        String s3 = list.get(2);
        String s4 = list.get(3);
        String s5 = list.get(4);
        System.out.println(s1);
        System.out.println(s2);
        System.out.println(s3);
        System.out.println(s4);
        System.out.println(s5);

        System.out.println("--------------------------");

        String str = list.toString();
        System.out.println(str);
    }
}
